/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package pagoda.engine;

import java.io.Serializable;
import java.util.UUID;

/**
 *
 * @author Kevin Krohe
 */
public class TestActionResult implements Serializable{

    public TestActionStatus Status = TestActionStatus.NotRun;
    public String Message;
    public UUID ActionId;

    public TestActionResult MergeSubResult(TestActionResult subResult)
    {
        if(subResult == null)
            return this;
        if(subResult.Status.compareTo(Status) > 0)
        {
            Status = subResult.Status;
            Message = String.format("%s", Message, subResult.Message);
        }
        return this;
    }
}
